//
// Created by LiuYou on 2021/6/18.
//

#ifndef LINUXENVIRONMENTPROGRAMMING_MYTBF_HPP
#define LINUXENVIRONMENTPROGRAMMING_MYTBF_HPP

namespace MyTokenBucket {
    constexpr int getMyTBFMax();

    typedef void MyTBF;

    MyTBF* myTbfInit(int cps, int burst);

    int fetchToken(MyTBF*, int);

    int returnToken(MyTBF*, int);

    int myTbfDestroy(MyTBF*);
}


#endif //LINUXENVIRONMENTPROGRAMMING_MYTBF_HPP
